//
//  WFHandleURL.m
//  谷居
//
//  Created by dllo on 16/6/18.
//  Copyright © 2016年 刘万方. All rights reserved.
//

#import "WFHandleURL.h"

@implementation WFHandleURL
/** case页面的网址处理. */
+ (NSString *)caseHanleURLWithStyle:(NSInteger)style type:(NSInteger)type area:(NSInteger)area cost:(NSInteger)cost user:(NSString *)user start:(NSInteger)start count:(NSInteger)count {
    NSString *URL = [NSString stringWithFormat:@"http://api.guju.com.cn/v2/project/list?style=%ld&type=%ld&area=%ld&cost=%ld&user=%@&start=%ld&count=%ld", style, type, area, cost, user, start, count];
    return URL;
}

/** Pics页面的请求. */
+ (NSString *)picsHandleURLWithSortId:(NSInteger)sortId start:(NSInteger)start count:(NSInteger)count userId:(NSInteger)userId space:(NSInteger)space style:(NSInteger)style color:(NSInteger)color {
    NSString *url = [NSString stringWithFormat:@"http://api.guju.com.cn/v2/photo/flow?sortId=%ld&start=%ld&count=%ld&userId=%ld&space=%ld&style=%ld&color=%ld", sortId, start, count, userId, space, style, color];
    return url;
}

+ (NSString *)guideHandleURLWithUserId:(NSInteger)userId count:(NSInteger)count start:(NSInteger)start orderString:(NSString *)orderString cateGory:(NSInteger)cateGory {
    NSString *url = [NSString stringWithFormat:@"http://api.guju.com.cn/v2/strategy/strategyList?userId=%ld&count=%ld&start=%ld&orderString=%@&category=%ld", userId, count, start, orderString, cateGory];
    return url;
}

/** 获取图片网址. */
+ (NSString *)getPicURL:(NSInteger)picId {
    NSString *str = [NSString stringWithFormat:@"http://img.guju.com.cn/dimages/%ld_0_w320_h0_m0.jpg", picId];
    return str;
}

/** 获取点击进入的userID和id. */
+ (NSString *)getClickUrl:(NSInteger)userId id:(NSInteger)id {
    NSString *str = [NSString stringWithFormat:@"http://api.guju.com.cn/v2/project/%ld/v2?userId=%ld", id, userId];
    return str;
}


@end
